using Nuwanda.TfsSpotlight.Shell.Proxies.Interfaces;

namespace Nuwanda.TfsSpotlight.Shell.Expressions
{
    internal class SaveFileDialogConfigurationExpression : ISaveFileDialogConfigurationExpression
    {
        private ISaveFileDialog SaveFileDialog { get; set; }

        public SaveFileDialogConfigurationExpression(ISaveFileDialog saveFileDialog)
        {
            this.SaveFileDialog = saveFileDialog;
        }

        public ISaveFileDialogConfigurationExpression Filter(string filter, int filterIndex)
        {
            this.SaveFileDialog.SetFilter(filter, filterIndex);
            return this;
        }

        public ISaveFileDialogConfigurationExpression RestoreDirectory()
        {
            this.SaveFileDialog.RestoreDirectory = true;
            return this;
        }
    }
}